package com.ftg.learn.chapter08.interface1.carinterface;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 车 类
 *
 * @author lijiaxin
 * @version 1.0
 * @date 2023/7/27 14:15
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class Car implements Emissions{

    private String color;
    private String brand;
    private String sub_brand;

    public static void main(String[] args) {
        Car c1=new Car("红色","福特","野马");
        Car c2=new Car("蓝色","丰田","普锐斯");
        Car c3=new Car("绿色","大众","高尔夫");


        System.out.println(c2);
        c2.Emissions();

    }

    @Override
    public void Emissions() {
        System.out.println("排放量不能超过100");
    }
}
